<%@tag pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@attribute name="item" required="true" type="cn.livingCloud.dto.AddressDto" %>

<td>${item.name}</td>
<td>
    <span class="label label-warning">${item.memberName}</span>
</td>
<td>
    <span class="label label-primary">${item.phone}</span>
</td>
<td>
    <span class="label label-primary">${item.code}</span>
</td>
<td>
    <button data-content="${item.address}" data-placement="bottom"
            data-toggle="popover" data-container="body" class="label label-default popovers" type="button"
            data-original-title="" title="">
        ${item.shortAddress}
    </button>
</td>
<td>
    <c:if test="${not item.acquiesce}">
        <span class="label label-danger">否</span>
    </c:if>
    <c:if test="${item.acquiesce}">
        <span class="label label-success">是</span>
    </c:if>
</td>
<td>
    <span class="label label-info">${item.createTime}</span>
</td>
<td>
    <c:if test="${item.acquiesce}">
        <button type="button" class="btn btn-warning ChangeState"
                uuid="${item.uuid}" state="false" name="${item.name}">设为非默认
        </button>
    </c:if>
    <c:if test="${not item.acquiesce}">
        <button type="button" class="btn btn-success ChangeState"
                uuid="${item.uuid}" state="true" name="${item.name}">设为默认
        </button>
    </c:if>
    <a class="btn btn-primary" href="${contextPath}/admin/goods/address/edit.htm?uuid=${item.uuid}">编辑地址</a>
    <a class="btn btn-danger" href="${contextPath}/admin/goods/delete.htm?uuid=${item.uuid}"
       onclick="javascript:return confirm('确定删除商品[${item.name}]?');">删除</a>
</td>

